<!--
  运营-招聘管理-【招聘职位】
 -->
<template>
  <div class="news-container">
    <el-tabs v-model="activeName" type="card" @tab-click="handleClick">
      <!-- <el-tab-pane label="待审核" name="1">
        <WaitAudited ref="studentMsg" />
      </el-tab-pane>
      <el-tab-pane label="已审核" name="2">
        <Audited ref="msgType" />
      </el-tab-pane> -->
      <el-tab-pane label="遴选" name="1">
        <LinxuanList ref="linxuanList" />
      </el-tab-pane>
      <el-tab-pane label="初赛" name="2">
        <OtherStatusList ref="otherStatusList1" :scheduleType="2" />
      </el-tab-pane>
      <el-tab-pane label="复赛" name="3">
        <OtherStatusList ref="otherStatusList2" :scheduleType="3" />
      </el-tab-pane>
      <el-tab-pane label="决赛" name="4">
        <OtherStatusList ref="otherStatusList3" :scheduleType="4" />
      </el-tab-pane>
    </el-tabs>
  </div>
</template>

<script>
import { searchConfig, tableConfig } from './initData';
import LinxuanList from './linxuanList.vue';
import OtherStatusList from './otherStatusList.vue'

export default {
  name: 'Company',
  components: {
    LinxuanList,
    OtherStatusList
  },
  data() {
    return {
      searchConfig,
      tableConfig,
      tableData: [
        {
          id: '01',
          title: '这是测试标题'
        }
      ],
      total: 0,
      page: 0,
      limit: 0,
      tableSelectList: [],
      activeName: '1'
    }
  },
  created() {
  },
  methods: {
    handleClick(data) {
      const refEnum = {
        "1": "linxuanList",
        "2": "otherStatusList1",
        "3": "otherStatusList2",
        "4": "otherStatusList3"
      }
      this.$refs[refEnum[this.activeName]] && this.$refs[refEnum[this.activeName]].handleSearch();
    }
  }
}
</script>

<style lang="scss" scoped>
  .news-container {
    
    .header {
      display: flex;
      justify-content: space-between;
    }
  }
</style>

<style lang="scss">
  .competitionManage-yunying {
    .basic-table {
      .el-table__body-wrapper {
        height: calc(100vh - 256px);
      }
    }
    .basic-table::before {
      height: 0;
    }

    .pagination-container {
      padding: 0 !important;
    }
  }
</style>